<template>
  <el-form class="tl-form" ref="form" label-width="100px">
    <el-timeline>
      <el-timeline-item v-for="(item, index) in feedbackList" :key="index" color="#0A6ED2" style="margin-top: 20px;margin-left: -40px;"  :timestamp="item.submitdate" placement="top" v-show="showMore || index < 2">
        <el-card>
          <ul>
              <li>
                <p><span class="operate">反馈人：</span><span class="column"> {{item.username}} </span></p>
              </li>
              <li>
                <p><span class="operate">进度更新：</span><span class="column"> {{item.completion}} </span></p>
              </li>
              <li>
                <p><span class="operate">本周提升分数：</span><span class="column"> {{item.improvescore}} </span></p>
              </li>
              <li>
                <p><span class="operate">完成得分：</span><span class="column"> {{item.completionscore}} </span></p>
              </li>
              <li v-if="item.dispisfinishbidscore">
                <p><span class="operate">是否完成：</span><span class="column"> {{item.dispisfinishbidscore}} </span></p>
              </li>
          </ul>
        </el-card>
      </el-timeline-item>
    </el-timeline>
    <el-button type="text" icon="el-icon-arrow-down" v-show="!showMore && feedbackList.length > 2" @click="showMore = !showMore">查看全部</el-button>
    <el-button type="text" icon="el-icon-arrow-up" v-show="showMore && feedbackList.length > 2" @click="showMore = !showMore">收起</el-button>
  </el-form>
</template>

<script>
/** mixins */
import { mixin_approval_edit } from '@tapui/mixins/mixin_approval_edit'
/** 工具类 */
import { putAction, getAction, postAction, deleteAction } from "@tapui/utils/http"
/** VUE配置 */
export default {
  mixins: [mixin_approval_edit],
  data() {
    return {
      urlPrefix: '/mpm/projectTaskFeedback/',
      url: {
        list: '/mpm/projectTaskFeedback/list'
      },
      showMore: false
    }
  },
  props: {
    feedbackList: []
  },
  methods: { }
}
</script>
